<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<!-- /fasttmp/mkdist-qt-4.3.5-1211793125/qtopia-core-opensource-src-4.3.5/src/xml/qdom.cpp -->
<head>
  <title>Qt 4.3: QDomNodeList Class Reference</title>
  <link href="classic.css" rel="stylesheet" type="text/css" />
</head>
<body>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="left" valign="top" width="32"><a href="http://www.trolltech.com/products/qt"><img src="images/qt-logo.png" align="left" width="32" height="32" border="0" /></a></td>
<td width="1">&nbsp;&nbsp;</td><td class="postheader" valign="center"><a href="index.html"><font color="#004faf">Home</font></a>&nbsp;&middot; <a href="classes.html"><font color="#004faf">All&nbsp;Classes</font></a>&nbsp;&middot; <a href="mainclasses.html"><font color="#004faf">Main&nbsp;Classes</font></a>&nbsp;&middot; <a href="groups.html"><font color="#004faf">Grouped&nbsp;Classes</font></a>&nbsp;&middot; <a href="modules.html"><font color="#004faf">Modules</font></a>&nbsp;&middot; <a href="functions.html"><font color="#004faf">Functions</font></a></td>
<td align="right" valign="top" width="230"><a href="http://www.trolltech.com"><img src="images/trolltech-logo.png" align="right" width="203" height="32" border="0" /></a></td></tr></table><h1 align="center">QDomNodeList Class Reference<br /><sup><sup>[<a href="qtxml.html">QtXml</a> module]</sup></sup></h1>
<p>The QDomNodeList class is a list of <a href="qdomnode.html">QDomNode</a> objects. <a href="#details">More...</a></p>
<pre> #include &lt;QDomNodeList&gt;</pre><p><b>Note:</b> All the functions in this class are <a href="threads.html#reentrant">reentrant</a>.</p>
<ul>
<li><a href="qdomnodelist-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="public-functions"></a>
<h3>Public Functions</h3>
<ul>
<li><div class="fn"/><b><a href="qdomnodelist.html#QDomNodeList">QDomNodeList</a></b> ()</li>
<li><div class="fn"/><b><a href="qdomnodelist.html#QDomNodeList-2">QDomNodeList</a></b> ( const QDomNodeList &amp; <i>n</i> )</li>
<li><div class="fn"/><b><a href="qdomnodelist.html#dtor.QDomNodeList">~QDomNodeList</a></b> ()</li>
<li><div class="fn"/>QDomNode <b><a href="qdomnodelist.html#at">at</a></b> ( int <i>index</i> ) const</li>
<li><div class="fn"/>int <b><a href="qdomnodelist.html#count">count</a></b> () const</li>
<li><div class="fn"/>bool <b><a href="qdomnodelist.html#isEmpty">isEmpty</a></b> () const</li>
<li><div class="fn"/>QDomNode <b><a href="qdomnodelist.html#item">item</a></b> ( int <i>index</i> ) const</li>
<li><div class="fn"/>uint <b><a href="qdomnodelist.html#length">length</a></b> () const</li>
<li><div class="fn"/>int <b><a href="qdomnodelist.html#size">size</a></b> () const</li>
<li><div class="fn"/>bool <b><a href="qdomnodelist.html#operator-not-eq">operator!=</a></b> ( const QDomNodeList &amp; <i>n</i> ) const</li>
<li><div class="fn"/>QDomNodeList &amp; <b><a href="qdomnodelist.html#operator-eq">operator=</a></b> ( const QDomNodeList &amp; <i>n</i> )</li>
<li><div class="fn"/>bool <b><a href="qdomnodelist.html#operator-eq-eq">operator==</a></b> ( const QDomNodeList &amp; <i>n</i> ) const</li>
</ul>
<a name="details"></a>
<hr />
<h2>Detailed Description</h2>
<p>The QDomNodeList class is a list of <a href="qdomnode.html">QDomNode</a> objects.</p>
<p>Lists can be obtained by <a href="qdomdocument.html#elementsByTagName">QDomDocument::elementsByTagName</a>() and <a href="qdomnode.html#childNodes">QDomNode::childNodes</a>(). The Document Object Model (DOM) requires these lists to be &quot;live&quot;: whenever you change the underlying document, the contents of the list will get updated.</p>
<p>You can get a particular node from the list with <a href="qdomnodelist.html#item">item</a>(). The number of items in the list is returned by <a href="qdomnodelist.html#length">length</a>().</p>
<p>For further information about the Document Object Model see <a href="http://www.w3.org/TR/REC-DOM-Level-1/">Level 1</a> and <a href="http://www.w3.org/TR/DOM-Level-2-Core/">Level 2 Core</a>. For a more general introduction of the DOM implementation see the <a href="qdomdocument.html">QDomDocument</a> documentation.</p>
<p>See also <a href="qdomnode.html#childNodes">QDomNode::childNodes</a>() and <a href="qdomdocument.html#elementsByTagName">QDomDocument::elementsByTagName</a>().</p>
<hr />
<h2>Member Function Documentation</h2>
<h3 class="fn"><a name="QDomNodeList"></a>QDomNodeList::QDomNodeList ()</h3>
<p>Creates an empty node list.</p>
<h3 class="fn"><a name="QDomNodeList-2"></a>QDomNodeList::QDomNodeList ( const QDomNodeList &amp; <i>n</i> )</h3>
<p>Constructs a copy of <i>n</i>.</p>
<h3 class="fn"><a name="dtor.QDomNodeList"></a>QDomNodeList::~QDomNodeList ()</h3>
<p>Destroys the object and frees its resources.</p>
<h3 class="fn"><a name="at"></a><a href="qdomnode.html">QDomNode</a> QDomNodeList::at ( int <i>index</i> ) const</h3>
<p>This function is provided for Qt API consistency. It is equivalent to <a href="qdomnodelist.html#item">item</a>().</p>
<p>If <i>index</i> is negative or if <i>index</i> &gt;= <a href="qdomnodelist.html#length">length</a>() then a null node is returned (i.e&#x2e; a node for which <a href="qdomnode.html#isNull">QDomNode::isNull</a>() returns true).</p>
<h3 class="fn"><a name="count"></a>int QDomNodeList::count () const</h3>
<p>This function is provided for Qt API consistency. It is equivalent to <a href="qdomnodelist.html#length">length</a>().</p>
<h3 class="fn"><a name="isEmpty"></a>bool QDomNodeList::isEmpty () const</h3>
<p>Returns true if the list contains no items; otherwise returns false. This function is provided for Qt API consistency.</p>
<h3 class="fn"><a name="item"></a><a href="qdomnode.html">QDomNode</a> QDomNodeList::item ( int <i>index</i> ) const</h3>
<p>Returns the node at position <i>index</i>.</p>
<p>If <i>index</i> is negative or if <i>index</i> &gt;= <a href="qdomnodelist.html#length">length</a>() then a null node is returned (i.e&#x2e; a node for which <a href="qdomnode.html#isNull">QDomNode::isNull</a>() returns true).</p>
<p>See also <a href="qdomnodelist.html#length">length</a>().</p>
<h3 class="fn"><a name="length"></a><a href="qtglobal.html#uint-typedef">uint</a> QDomNodeList::length () const</h3>
<p>Returns the number of nodes in the list.</p>
<h3 class="fn"><a name="size"></a>int QDomNodeList::size () const</h3>
<p>This function is provided for Qt API consistency. It is equivalent to <a href="qdomnodelist.html#length">length</a>().</p>
<h3 class="fn"><a name="operator-not-eq"></a>bool QDomNodeList::operator!= ( const QDomNodeList &amp; <i>n</i> ) const</h3>
<p>Returns true the node list <i>n</i> and this node list are not equal; otherwise returns false.</p>
<h3 class="fn"><a name="operator-eq"></a>QDomNodeList &amp; QDomNodeList::operator= ( const QDomNodeList &amp; <i>n</i> )</h3>
<p>Assigns <i>n</i> to this node list.</p>
<h3 class="fn"><a name="operator-eq-eq"></a>bool QDomNodeList::operator== ( const QDomNodeList &amp; <i>n</i> ) const</h3>
<p>Returns true if the node list <i>n</i> and this node list are equal; otherwise returns false.</p>
<p /><address><hr /><div align="center">
<table width="100%" cellspacing="0" border="0"><tr class="address">
<td width="30%">Copyright &copy; 2008 <a href="trolltech.html">Trolltech</a></td>
<td width="40%" align="center"><a href="trademarks.html">Trademarks</a></td>
<td width="30%" align="right"><div align="right">Qt 4.3.5</div></td>
</tr></table></div></address></body>
</html>
